//默认分页样式
export const pagination = {
    current: 1, //当前页码
    total: 0, // 总条数
    pageSize: 10, //每页中显示10条数据
    showTotal: total => `共${total} 条数据`, //分页中显示总的数据
    showSizeChanger: true,
}


//======================


//微信小程序用户
export const userTable = [
    {
        title: 'openId',
        align: 'center',
        dataIndex: 'openId',
        width: 200,
        ellipsis: true,


    },
    {
        title: '头像',
        dataIndex: 'avatarUrl',
        align: 'center',
        width: 80,
        scopedSlots: {
            customRender: 'avatarUrl'
        }

    },


    {
        title: '昵称',
        align: 'left',
        dataIndex: 'nickName',
        width: 200,

    },


    {
        title: '性别',
        align: 'center',
        dataIndex: 'sex',
        width: 80,


    },


    {
        title: '国家',
        dataIndex: 'country',
        width: 100,
        ellipsis: true,

    },


    {
        title: '省份',
        width: 100,
        dataIndex: 'province',
        ellipsis: true,
    },
    {
        title: '城市',
        align: 'center',
        width: 100,
        dataIndex: 'city',
        ellipsis: true,

    },

    {
        title: '手机号码',
        align: 'left',
        width: 120,
        dataIndex: 'phoneNumber',
        ellipsis: true,

    },


    {
        title: '推广Id',
        align: 'center',
        dataIndex: 'promoterId',
        width: 100,
        ellipsis: true,


    },

    {
        title: '建档时间',
        align: 'center',
        width: 200,
        dataIndex: 'createTime',
        ellipsis: true,

    },
    {
        title: '更新时间',
        align: 'center',
        width: 200,
        dataIndex: 'updateTime',
        ellipsis: true,

    },


];


//推广素材
export const materialTable = [
    {
        title: '编号',
        dataIndex: 'id',
        align: 'center',
        width: 180,
        ellipsis: true,

    },

    {
        title: '素材标题',
        align: 'left',
        ellipsis: true,

        dataIndex: 'title',

    },

    {
        title: '推广页面',
        width: 150,
        dataIndex: 'appPath',
    },


    {
        title: '素材尺寸',
        align: 'center',
        width: 150,
        customRender: record => record.width + "*" + record.height + 'px'
    },

    {
        title: '二维码大小',
        width: 150,
        customRender: record => record.qrcodeSize + 'px'
    },

    {
        title: '透明度',
        width: 150,
        customRender: record => record.transparency  +'%'
    },


    {
        title: '发布时间',
        align: 'center',
        width: 180,
        dataIndex: 'createTime',
        ellipsis: true,

    },


    {
        title: '操作',
        dataIndex: 'operation',
        align: 'center',
        width: 200,
        scopedSlots: {
            customRender: 'operation'
        }
    }
];